Repository navigation
feat(generator): generate the SDK from the OpenAPI spec - #12
Merged
Merged
Conversation
Parse the committed spec into a stable, operation-ID sorted inventory and derive one Java binding per operation (service folder, service name, method, request/pagination shape). Config-driven overrides keep the vended SDK names and types; the validator rejects missing path parameters, duplicate methods, and one service name bound to two folders. - SpecParser fails on operations without an operationId. - SpecFetcher replaces the committed spec only after a 2xx response that parses with operations. - JavaTypeResolver maps schemas to vended model/enum types, keeps DTO booleans boxed, and rejects ambiguous inline enums. - operation-inventory.json locks the vended service and method of all 111 current operations; new spec operations are allowed.
Post-process raw OpenAPI models so *ErrorCode/*Subcode enums land in com.coinbase.prime.model.errors and every other enum keeps its vended package. Model output is tracked in a manifest, so stale files are removed only when the previous generation owned them, and enum directory read errors fail generation instead of emitting partial imports.
✅ Heimdall Review Status
|
This was referenced Nov 20, 2026
rcbgr
previously approved these changes
Nov 24, 2026
nmorgan-cb
force-pushed
the
feat/generator-1-bindings
branch
from
November 24, 2026 19:26
614c52d to
67003db
Compare
nmorgan-cb
commented
Nov 24, 2026
nmorgan-cb
left a comment
Contributor
Author
There was a problem hiding this comment.
Needs a couple of comments addressed
rcbgr
previously approved these changes
Nov 24, 2026
… vended layout - Emit request/response DTOs, service interfaces/impls, and PrimeServiceFactory - Add make generate and make check-generated targets and CoinbasePrimeClient.withBaseUrl - Add deprecated subclass aliases from operations-overrides.json and align 14 method names with Go, Python, and TypeScript SDKs - Preserve vended class layout, Javadoc, and member ordering via SourceLayout - Lock operation inventory and cross-SDK naming parity in generator tests
… order examples - Add optional limit_price, stop_price, and time_in_force CLI arguments to CreateOrder and CreateOrderPreview - Default time_in_force to GOOD_UNTIL_CANCELLED when limit_price is supplied for LIMIT or STOP_LIMIT orders
nmorgan-cb
force-pushed
the
feat/generator-1-bindings
branch
from
November 24, 2026 21:27
317b563 to
6056e8a
Compare
5 of 9 tasks
cfluke-cb
approved these changes
Nov 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds automated generation of the SDK from the OpenAPI spec. No generated SDK output is committed.
make generatebuilds models, request/response DTOs, services andPrimeServiceFactoryfromapiSpec/prime-public-spec.yaml.@Deprecatedalias of the old name, set inoperations-overrides.json, so existing callers still compile.Type of Change
Checklist